package com.example.weatherforecast.whtrcdn.entity

import com.example.weatherforecast.whtrcdn.net.Forecast
import com.example.weatherforecast.whtrcdn.net.Yesterday

data class WeatherForecastInfo
    (
    var weekday: String,
    var type: String,
    var temperatureBoundary: String,
    var date: String) {

    companion object {
        fun generate(forecast: Forecast): WeatherForecastInfo {
            return WeatherForecastInfo(forecast.date, forecast.type, forecast.low + "~" + forecast.high, "")
        }

        fun generate(forecast: Yesterday): WeatherForecastInfo {
            return WeatherForecastInfo(forecast.date, forecast.type, forecast.low + "~" + forecast.high, "")
        }
    }

    }